package com.xing.test;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class test1 {
    public static void main(String[] args) {
        ApplicationContext applicationContext=new ClassPathXmlApplicationContext("spring.xml");
        String[] names=applicationContext.getBeanDefinitionNames();
        for (String name:names){
            System.out.println(applicationContext.getBean(name));
        }
    }
}
